<?php
/* 
 * ebiz front
 * 
 * all opinion View
 * 
 * @author allen
 * 
 */
require_once '../app/util/CommonUtil.php';
?> 
        

<!--交易评价分页开始-->
<div id="pro_pingjia">
    <div class="pingjia_title">
        <div class="pj_left_title">
            <ul>
                <li class="title_1">全部评论</li>
                <!-- 
                <li class="title_2">手机</li>
                <li class="title_2">数码</li>
                <li class="title_2">化妆品</li>
                <li class="title_2">日用百货</li>
                 -->
            </ul>
        </div> 
        <div class="pj_right_title">
            <p><a href="#">如何发布交易评价？</a></p>
        </div>   
    </div>
    <div class="pingjia_body">
        <div id="pingjia_1">
         
        <?php 
            foreach ($result as $opinionItem) {
        ?>
        
            <div class="pj_border">
                <!--左侧会员信息开始-->
                <div class="pj_left">
                    <div class="pj_user_img">
                        <img src="<?php echo ConfigConstants::getTLayoutPath()."/image/rankpic/{$opinionItem['userranknum']}.jpg"; ?>" alt="" />
                    </div>
                    <p>用户名：<span><?php echo $opinionItem["username"]; ?></span></p>
                    <p>会员等级：<span><?php echo $opinionItem["userrank"]; ?></span></p>
                </div>
                <!--左侧会员信息结束-->
                <!--右侧评价信息开始-->
                <div class="pj_right">
                    <div class="pj_body_bt">
                        <ul>
                        
                            <?php 
                                if(!empty($opinionItem["productTitle"])){
                            ?>
                            <li class="title_1">产品名称：</li>
                            
                            <?php if(empty($opinionItem["productUrlTitle"])){?>
                            <li class="title_2" title="<?php echo $opinionItem["productTitle"]; ?>">
                            <?php }else{ ?>
                            <li class="title_2" style="cursor:pointer;" onclick="window.open('/p/<?php echo urlencode($opinionItem["productUrlTitle"]); ?>');" title="<?php echo $opinionItem["productTitle"]; ?>">
                            <?php } ?>
                            
                            <?php echo CommonUtil::sysSubStr($opinionItem["productTitle"], 30, true); ?>
                            </li>
                            <?php } ?>
                            <!-- 
                            <li class="title_1">用户类型：</li>
                            <li class="title_2"><?php //echo $opinionItem["userrank"]; ?></li>
                             -->
                            <?php if(!empty($opinionItem["paymentTitle"])){ ?>
                            <li class="title_1">支付方式：</li>
                            <li class="title_2"><?php echo $opinionItem["paymentTitle"]; ?></li>
                            <?php } ?>
                            <?php if(!empty($opinionItem["shippingTitle"])){ ?>
                            <li class="title_1">快递方式：</li>
                            <li class="title_2"><?php echo $opinionItem["shippingTitle"]; ?></li>
                            <?php } ?>
                            <?php if(!empty($opinionItem["buyTime"])){ ?>
                            <li class="title_1">购买时间：</li>
                            <li class="title_2"><?php echo $opinionItem["buyTime"]; ?></li>
                            <?php } ?>
                            
                        </ul>
                    </div>
                    <div class="pj_pinglun">
                        <p>用户评论：</p>
                        <?php echo $opinionItem["content"]; ?><span>&nbsp;&nbsp;发表于&nbsp;<?php echo $opinionItem["created"]; ?></span>
                    </div>
                    
                    <?php if(!empty($opinionItem["reply_content"])){?>
                    <div class="pj_pl_hf">
                        <p>米米回复：</p>
                        <?php echo $opinionItem["reply_content"]; ?><span>&nbsp;&nbsp;回复于&nbsp;<?php echo $opinionItem["reply_created"]; ?></span>
                    </div>
                    <?php } ?>
                    
                </div>
                <!--右侧评价信息结束-->
                <p class="hr"></p>
            </div>
            
        <?php }?>
        
        </div>    
    </div>
</div>
<!--交易评价分页完-->


<!--分页开始-->
<div class="eav_page" style="padding-left:0px;">
    <div class='p2_page' ><?php echo $headerPaginate; ?></div>
</div>             
<!--分页结束-->

